#'###########################################
#'                                          #
#'  ------------------------------------    #
#'  |     COIN     __                  |    #
#'  |            >(' )                 |    #
#'  |              )/                  |    #
#'  |             /  `----/            |    #
#'  |             \  ~=- /             |    #
#'  |   ~^~^~^~^~^~^~^~^~^~^~^~^~^~^   |    #
#'  ------------------------------------    #
#'                                          #
#'###########################################


if (!exists("R_ROOT")) {
	R_ROOT <- "C:/UQAR/Recherche/Maitrise/Donnees"
}
if (!exists("R_WORKING_DIRECTORY")) {
	R_WORKING_DIRECTORY <- file.path(R_ROOT, "R")
}
if (!exists("R_DATA_PATH")) {
	R_DATA_PATH <- file.path(R_ROOT, "Donnees")
}
if (!exists("R_RESULTS_PATH")) {
	R_RESULTS_PATH <- file.path(R_ROOT, "Resultats")
}



SESSION_INFO_FILE <- file.path(R_DATA_PATH, "Prise_donnees_2012.csv")
INFO_DATE_FORMAT <- "%d/%m/%y"

R_PACKAGES <- c("data.table", "grid", "chron", "stringr", "adehabitatHR", "rgeos", "parallel",
				"proj4", "Rmisc", "boot", "MASS", "compositions", "nlme", "LMERConvenienceFunctions", "lattice",
				"latticeExtra", "argosfilter", "lmerTest", "extrafont", "robCompositions", "afex", "ggplot2")
		
for (i in R_PACKAGES) {
	library(i, character.only=TRUE)
}



source(file.path(R_WORKING_DIRECTORY, "Utils/utils.R"))
source(file.path(R_WORKING_DIRECTORY, "Utils/fileUtils.R"))
source(file.path(R_WORKING_DIRECTORY, "Utils/HRUtils.R"))
source(file.path(R_WORKING_DIRECTORY, "Utils/statsUtils.R"))
source(file.path(R_WORKING_DIRECTORY, "Utils/graphUtils.R"))
source(file.path(R_WORKING_DIRECTORY, "Utils/generatePointsUtils.R"))
source(file.path(R_WORKING_DIRECTORY, "Utils/constants.R"))
source(file.path(R_WORKING_DIRECTORY, "Utils/rsquaredlme.R"))

source(file.path(R_WORKING_DIRECTORY, "DataManagement/extractMobileData.R"))
source(file.path(R_WORKING_DIRECTORY, "DataManagement/extractStaticData.R"))
source(file.path(R_WORKING_DIRECTORY, "DataManagement/loadData.R"))
source(file.path(R_WORKING_DIRECTORY, "DataManagement/getError.R"))

source(file.path(R_WORKING_DIRECTORY, "FiltreMaison/SpeedFilter.R"))